package com.ctshk.rpc.system.req;

import com.ctshk.common.enums.SystemBusinessType;
import io.swagger.annotations.ApiModel;
import io.swagger.annotations.ApiModelProperty;
import lombok.Data;
import org.springframework.core.io.Resource;
import org.springframework.lang.Nullable;
import org.springframework.util.FileCopyUtils;

import java.io.File;
import java.io.IOException;
import java.io.InputStream;
import java.io.Serializable;
import java.nio.file.Files;
import java.nio.file.Path;
import java.util.List;

/**
 * <p>
 *
 * </p>
 *
 * @author 胡广
 * @since 2021/3/29
 */
@ApiModel("上传文件请求实体")
@Data
public class UploadReq implements Serializable {

    private static final long serialVersionUID = 1L;

    @ApiModelProperty("id")
    private String id;

    @ApiModelProperty("业务类型")
    private SystemBusinessType businessType;

    @ApiModelProperty("文件名称")
    private String name;

    @ApiModelProperty("原文件名称")
    private String originalFilename;

    @ApiModelProperty("文本类型")
    private String contentType;

    private boolean empty;

    @ApiModelProperty("文件大小")
    private long size;

    @ApiModelProperty("文件字节码")
    private byte[] bytes;

    @ApiModelProperty("文件后缀")
    private String fileSuffix;

    @ApiModelProperty("文件全称")
    private String fullName;
}
